﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.Text.RegularExpressions;

namespace MyMovieInfo
{
    class FileUtils
    {
        public static List<string> GetListFromFileSystem(string path, string ext)
        {
            //TODO: make recursive for subdirectories
            //OCP - not just for movies anymore, yay.
            var movieFiles = (from file in new DirectoryInfo(path).GetFiles()
                              where file.Extension == ext
                              select file.FullName).ToList<string>();

            return movieFiles;
        }
    }
}
